<div class="wedgetail-form">
<h1><%= @title %></h1>
<% for @narrative in @narratives %>
	<fieldset>
		<legend><%= @narrative.narrative_date.strftime("%d/%m/%y")%>   <%= @narrative.title-%></legend>	
		<% content, partial = @narrative.convert %>
				<%= render(:partial=>partial,:object=>content)%>
		<br><hr><br>
		<%= "Created by "+ @narrative.author + "<br>" if @narrative.author && @narrative.author!=""%>
		<% if @narrative.narrative_type%>
		<%= link_to 'Update this '+ @narrative.narrative_type.narrative_type_name, :controller=>'entry',:action=>'new',:wedgetail=>@patient.wedgetail,:narrative=>@narrative.id %>
		<% else %>
				<%= link_to 'Update this record', :controller=>'entry',:action=>'new',:wedgetail=>@patient.wedgetail,:narrative=>@narrative.id %>
		<% end %>
		
	</fieldset>
<% end %>
</div>


<%= link_to "Back ", :controller=> :patients, :action=> :show, :id=>@patient.wedgetail %>
